﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Bdcs.Core.Entity
{
    /// <summary>
    /// LogW_210815数据模型对象
    /// </summary>
    [Serializable]
    public partial class LogW_210815Mod
    {
        /// <summary>
        /// 初始化LogW_210815数据模型对象
        /// </summary>
        public LogW_210815Mod()
        {
            
        }
        /// <summary>
        /// 初始化LogW_210815数据模型对象并给在SQL中不能为空的字段赋值
        /// </summary>
        /// <param name="iD">ID</param>
        /// <param name="occorTime">occorTime</param>
        public LogW_210815Mod(long iD,DateTime occorTime)
        {
            //给ID字段赋值
            this.ID = iD;
            //给occorTime字段赋值
            this.OccorTime = occorTime;
        }
        /// <summary>
        /// 初始化LogW_210815数据模型对象并给所有字段赋值
        /// </summary>
        /// <param name="iD">ID</param>
        /// <param name="pagename">pagename</param>
        /// <param name="url">url</param>
        /// <param name="result">result</param>
        /// <param name="occorTime">occorTime</param>
        public LogW_210815Mod(long iD,string pagename,string url,string result,DateTime occorTime)
        {
            //给ID字段赋值
            this.ID = iD;
            //给pagename字段赋值
            this.Pagename = pagename;
            //给url字段赋值
            this.Url = url;
            //给result字段赋值
            this.Result = result;
            //给occorTime字段赋值
            this.OccorTime = occorTime;
        }
        
		//属性存储数据的变量
        private long _iD;
        private string _pagename;
        private string _url;
        private string _result;
        private DateTime _occorTime;
        
        /// <summary>
        /// ID
        /// </summary>
        public long ID
        {
            get { return this._iD; }
            set { this._iD = value; }
        }
        /// <summary>
        /// pagename
        /// </summary>
        public string Pagename
        {
            get { return this._pagename; }
            set { this._pagename = value; }
        }
        /// <summary>
        /// url
        /// </summary>
        public string Url
        {
            get { return this._url; }
            set { this._url = value; }
        }
        /// <summary>
        /// result
        /// </summary>
        public string Result
        {
            get { return this._result; }
            set { this._result = value; }
        }
        /// <summary>
        /// occorTime
        /// </summary>
        public DateTime OccorTime
        {
            get { return this._occorTime; }
            set { this._occorTime = value; }
        }
        
        /// <summary>
        /// 对比两个LogW_210815数据模型对象是否一致
        /// </summary>
        /// <param name="obj">要进行比对的LogW_210815数据模型对象</param>
        /// <returns>返回是否一致，为true一致，为false不一致</returns>
        public override bool Equals(object obj)
        {
            //判断传入对象是否为null
            if (obj == null) return false;
            //将传入对象转换成LogW_210815数据模型对象
            LogW_210815Mod logW_210815Mod = obj as LogW_210815Mod;
            //判断是否转换成功
            if (logW_210815Mod == null) return false;
            //进行匹配属性的值
            return
                //判断ID是否一致
                this.ID == logW_210815Mod.ID &&
                //判断pagename是否一致
                this.Pagename == logW_210815Mod.Pagename &&
                //判断url是否一致
                this.Url == logW_210815Mod.Url &&
                //判断result是否一致
                this.Result == logW_210815Mod.Result &&
                //判断occorTime是否一致
                this.OccorTime == logW_210815Mod.OccorTime;
        }
        /// <summary>
        /// 将当前LogW_210815数据模型对象转换成哈希码
        /// </summary>
        /// <returns>哈希值</returns>
        public override int GetHashCode()
        {
            //将LogW_210815数据模型对象的属性进行按位异或运算处理得到哈希码并返回
            return
                //将ID进行按位异或运算处理
                this.ID.GetHashCode() ^
                //将pagename进行按位异或运算处理
                (this.Pagename == null ? 2147483647 : this.Pagename.GetHashCode()) ^
                //将url进行按位异或运算处理
                (this.Url == null ? 2147483647 : this.Url.GetHashCode()) ^
                //将result进行按位异或运算处理
                (this.Result == null ? 2147483647 : this.Result.GetHashCode()) ^
                //将occorTime进行按位异或运算处理
                this.OccorTime.GetHashCode();
        }
        /// <summary>
        /// 将当前LogW_210815数据模型对象转换成字符串副本【仅显示在SQL中不能为空的列】
        /// </summary>
        /// <returns>字符串形式副本</returns>
        public override string ToString()
        {
            //将当前LogW_210815数据模型对象转换成字符串副本
            return
                "[" +
                //将ID转换成字符串
                this.ID + "," +
                //将occorTime转换成字符串
                this.OccorTime +
                "]";
        }
    }
}
